<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>班级&学生管理系统</title>
    <link rel="stylesheet" href="./Public/bootstrap-3.3.0-dist/dist/css/bootstrap.min.css">
    <style>
        .box {
            width: 60%;
            margin: 40px auto;
        }
    </style>
</head>
<body>
<div class="box">
    <form class="form-horizontal" role="form" method="post">
        <div class="form-group">
            <label for="inputEmail3" class="col-sm-2 control-label">学生姓名</label>
            <div class="col-sm-10">
                <input type="text" value="<?php echo $oldStudent['sname']?>" class="form-control" id="inputEmail3" required name="sname">
            </div>
        </div>
        <div class="form-group">
            <label for="inputPassword3" class="col-sm-2 control-label">学生年龄</label>
            <div class="col-sm-10">
                <input type="number" min="1" value="<?php echo $oldStudent['age']?>" class="form-control" id="inputPassword3" required name="age">
            </div>
        </div>
        <div class="form-group">
            <label for="inputSex" class="col-sm-2 control-label" required>学生性别</label>
            <div class="col-sm-10">
                <div class="radio">
                    <label>
                        <input type="radio" name="sex" value="男" required <?php if($oldStudent['sex']=='男'){?>checked<?php }?>> 男
                    </label>
                    <label>
                        <input type="radio" name="sex" value="女" required <?php if($oldStudent['sex']=='女'){?>checked<?php }?>> 女
                    </label>
                </div>
            </div>
        </div>
        <div class="form-group">
            <label for="exampleInputEmail1" class="col-sm-2 control-label" >学生班级</label>
            <div class="col-sm-10">
                <select class="form-control" name="cid">
                <?php foreach($allClass as $v){?>
                    <option value="<?php echo $v['cid']?>" <?php if($v['cid']==$_GET['cid']){?>selected<?php }?>><?php echo $v['cname']?></option>
                <?php }?>
                </select>

            </div>
        </div>
        <div class="form-group">
            <div class="col-sm-offset-2 col-sm-10">
                <button type="submit" class="btn btn-info">提交</button>
            </div>
        </div>
    </form>
</div>
</body>
</html>